/////////////////////////////////////////
//
// shjzhang, 2020
//
/////////////////////////////////////////

#ifndef GPSTK_grace_sca2att_HPP
#define GPSTK_grace_sca2att_HPP

#include <iostream>
#include <cmath>
#include <vector>

#include "CommonTime.hpp"
#include "Triple.hpp"
#include "Matrix.hpp"
#include "Vector.hpp"
#include "ReferenceSystem.hpp"
#include "MJD.hpp"
#include "Xvt.hpp"

namespace gpstk
{
   class grace_sca2att
   {
   public:
      
      grace_sca2att()
         throw()
         : TimeOriginMJD(51544.5),
           pAttStream(NULL)
      {}
      
      virtual ~grace_sca2att()
      {}
      
      virtual void convert(std::string filename);

      virtual void setAttStream(std::ofstream& stream)
      {
          pAttStream = &stream;
      };

      virtual long double CommonTimeToSecond( CommonTime& t);

         // convert seconds to CommonTime
      virtual CommonTime secondToCommonTime( long double s );

      
   private:
   
      long double TimeOriginMJD;
      
      std::ofstream* pAttStream;
      
   }; // END of "class grace_sca2att"
   
} // END of "namespace gpstk"










#endif
